 @extends('home.layout.user')

@section('content')

<div class="uc-rgt user_answer_list">
  <div class="uc-top-bar">
    <div class="sort-nav" id="qqq">
      <a href="javascript:;" class="sort-nav-tab user_nav_child"  data="0">全部</a>
      <span class="sort-nav-bar"></span>
      <a href="javascript:;" class="sort-nav-tab user_nav_child"  data="1">被采纳</a>
      <script src="/js/jquery-1.8.3.min.js"></script>
      <script>
        $(function(){
            $('#qqq a').click(function(){
              // 设置元素背景
              $(this).addClass('cur');
              // 获取自定义属性
              var x =$(this).attr('data');
              // // 设置所有的div默认隐藏
              $('.userstyle').css('display','none');
              // // 让指定的div显示
              $('.userstyle:eq('+x+')').css('display','block');
            }).mouseout(function(){
              $(this).removeClass('cur');
            })
          })
      </script>
  </div>
      <div id="reco_list">

          <div id="userList_recommend" class="uc-lst reco_list">
            <div class="userstyle"  style="display:block;">
              <div>
                @foreach($arr as $k=>$v)
                <ul>
                  <li class="list_item">
                   <div class="uc-lst-info">
                      <div class="uc-tit-box">
                        <a href="/home/answer/{{$v['qid']}}" target="_blank" class="uc-lst-tit-blue">{{$v['q_title']}}</a></div>
                      <div class="uc-tit-box">
                        <a href="/home/answer/{{$v['qid']}}" target="_blank" class="uc-lst-tit2">{{$v['a_content']}}</a></div>
                      <div class="uc-lst-bar">
                        <div class="uc-lst-txt">{{$v['a_time']}}</div>

                    </div>
                    <div class="uc-tag-box">
                      <div class="uc-lst-tag8">
                        <i>
                        </i>
                        <div class="uc-lst-tag-tit">等待采纳</div></div>
                    </div>
                  </li>
                </ul>
                @endforeach
              </div>
              <div class="page-num">
               <!--  {!! $answer->render()!!} -->
              </div>
            </div>

           <!-- 向我推荐 -->
              <div id="userList_recommend" class="uc-lst reco_list">
              <div class="userstyle">
                  <div>
                    <div class="category-none"><i></i><div>暂时还没有人向您求助，去其他页面帮助他人解答疑惑吧~</div>
                    </div>
                    <ul>
                    </ul>
                  </div>
              </div>
            </div>
        </div>
    </div>
</div>
@endsection